package com.ruoyi.home.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.home.mapper.SuCampusAdsMapper;
import com.ruoyi.home.domain.SuCampusAds;
import com.ruoyi.home.service.ISuCampusAdsService;

/**
 * 校区公告Service业务层处理
 *
 * @author ruoyi
 * @date 2025-06-18
 */
@Service
public class SuCampusAdsServiceImpl implements ISuCampusAdsService
{
    @Autowired
    private SuCampusAdsMapper suCampusAdsMapper;

    /**
     * 查询校区公告
     *
     * @param id 校区公告主键
     * @return 校区公告
     */
    @Override
    public SuCampusAds selectSuCampusAdsById(Long id)
    {
        return suCampusAdsMapper.selectSuCampusAdsById(id);
    }

    /**
     * 查询校区公告列表
     *
     * @param suCampusAds 校区公告
     * @return 校区公告
     */
    @Override
    public List<SuCampusAds> selectSuCampusAdsList(SuCampusAds suCampusAds)
    {
        return suCampusAdsMapper.selectSuCampusAdsList(suCampusAds);
    }

    /**
     * 新增校区公告
     *
     * @param suCampusAds 校区公告
     * @return 结果
     */
    @Override
    public int insertSuCampusAds(SuCampusAds suCampusAds)
    {
        return suCampusAdsMapper.insertSuCampusAds(suCampusAds);
    }

    /**
     * 修改校区公告
     *
     * @param suCampusAds 校区公告
     * @return 结果
     */
    @Override
    public int updateSuCampusAds(SuCampusAds suCampusAds)
    {
        return suCampusAdsMapper.updateSuCampusAds(suCampusAds);
    }

    /**
     * 批量删除校区公告
     *
     * @param ids 需要删除的校区公告主键
     * @return 结果
     */
    @Override
    public int deleteSuCampusAdsByIds(Long[] ids)
    {
        return suCampusAdsMapper.deleteSuCampusAdsByIds(ids);
    }

    /**
     * 删除校区公告信息
     *
     * @param id 校区公告主键
     * @return 结果
     */
    @Override
    public int deleteSuCampusAdsById(Long id)
    {
        return suCampusAdsMapper.deleteSuCampusAdsById(id);
    }
}
